<template>
    <div class="block">
      <el-date-picker
        v-model="pickerTime"
        type="year"
        placeholder="选择年"
        :picker-options="pickerOptions">
      </el-date-picker>
    </div>
</template>

<script>
    export default {
        name: "YearTimePicker",
      data() {
        return {
          pickerTime: '',
          pickerOptions: {
            disabledDate(time) {
              return time.getTime() > Date.now();
            }
          },
        };
      }
    }
</script>

<style scoped>

</style>
